﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ucBCL_XeBom.ascx.cs" Inherits="UC_ucBCL_XeBom" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<asp:UpdatePanel ID="up1" runat="server">
        <ContentTemplate>
            <div class="panel panel-success">
                <div class="panel-heading">
                    <h3 class="panel-title">
                        Báo cáo lương sản lượng xe bơm
                        
                    </h3>
                </div>
                <div class="panel-body">
                    <div>
                        <asp:DropDownList ID="dlThang" AutoPostBack="true" runat="server" Width="150px" CssClass="form-control"
                            OnSelectedIndexChanged="dlThang_SelectedIndexChanged">
                        </asp:DropDownList>
                        <asp:DropDownList ID="dlNam" AutoPostBack="true" OnSelectedIndexChanged="dlThang_SelectedIndexChanged"
                            runat="server" Width="110px" CssClass="form-control">
                        </asp:DropDownList>
                        <asp:TextBox ID="txtTuNgay" runat="server" AutoPostBack="true" OnTextChanged="dlThang_SelectedIndexChanged"
                            placeholder="Từ ngày" Visible="true" Width="100px" CssClass="form-control"></asp:TextBox>&nbsp;
                        <asp:TextBox ID="txtDenNgay" runat="server" placeholder="Đến ngày" OnTextChanged="dlThang_SelectedIndexChanged"
                            AutoPostBack="true" Visible="true" Width="100px" CssClass="form-control"></asp:TextBox>
                        <cc1:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="txtTuNgay"
                            Format="dd/MM/yyyy">
                        </cc1:CalendarExtender>
                        <cc1:CalendarExtender ID="CalendarExtender3" runat="server" TargetControlID="txtDenNgay"
                            Format="dd/MM/yyyy">
                        </cc1:CalendarExtender>
                        <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender9" runat="server" FilterType="Custom,Numbers"
                            TargetControlID="txtTuNgay" ValidChars="/-" />
                        <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender10" runat="server" FilterType="Custom,Numbers"
                            TargetControlID="txtDenNgay" ValidChars="/-" />
                        
                        
                        <asp:DropDownList ID="dlLaiXe" ToolTip="Chọn lái xe" runat="server"
                            DataValueField="IDs" Width="250px" CssClass="form-control" 
                            DataTextField="HoTen">
                        </asp:DropDownList>
                        

                        <asp:DropDownList ID="dlTramTron" Visible="false" Enabled="false" ToolTip="Chọn trạm trộn" runat="server"
                            DataValueField="IDs" Width="150px" CssClass="form-control" DataTextField="TenTramTron">
                        </asp:DropDownList>
                        <asp:Button ID="btnXem" CssClass="btn btn-warning" runat="server" Text="Tìm kiếm"
                            OnClick="btnXem_Click" />
                        <asp:Button ID="btnSave" runat="server" Style="margin-left: 5px;"
                            Text="Xuất báo cáo" Visible="true" CssClass="btn btn-primary" OnClick="btnPrint_Click" />
                        
                        <asp:HiddenField ID="hdTuNgay" runat="server" />
                        <asp:HiddenField ID="hdDenNgay" runat="server" />
                        <asp:ValidationSummary ID="ValidationSummary1" HeaderText=""
                        ShowMessageBox="true" ValidationGroup="Them" ShowSummary="false" EnableClientScript="true"
                        runat="server" />
                    </div>
                    <div style="width: 100%; margin-top: 0px; overflow-x: auto;" class="wrapper">
                        <asp:GridView ID="GV" runat="server" AutoGenerateColumns="false" BackColor="White"
                            BorderColor="#CCCCCC" BorderStyle="None" BorderWidth="1px" CellPadding="1" EmptyDataText="Không có dữ liệu nào"
                            EnableModelValidation="True" ShowFooter="false" Width="99%" 
                            CssClass="form-control withall" onrowdatabound="GV_RowDataBound" 
                            onrowcreated="GV_RowCreated">
                            <Columns>
                                <asp:BoundField DataField="STT" HeaderText="STT" ItemStyle-HorizontalAlign="Center" />
                                <asp:BoundField DataField="NhanVien" HeaderText="Nhân viên" ItemStyle-CssClass="paddingleft" />
                                <asp:BoundField DataField="BoPhan" HeaderText="Bộ phận" ItemStyle-CssClass="paddingleft" />
                                <asp:BoundField DataField="ChucVu" HeaderText="Chức vụ" ItemStyle-CssClass="paddingleft" />
                                
                                
                                <asp:BoundField DataField="SC1" HeaderText="Số ca" ItemStyle-HorizontalAlign="Center" />
                                <asp:BoundField DataField="DG1" HeaderText="Đơn giá" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                                <asp:BoundField DataField="TT1" HeaderText="Thành tiền" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />

                                <asp:BoundField DataField="SC2" HeaderText="Khối lượng" ItemStyle-HorizontalAlign="Center" />
                                <asp:BoundField DataField="DG2" HeaderText="Đơn giá" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                                <asp:BoundField DataField="TT2" HeaderText="Thành tiền" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />

                                <asp:BoundField DataField="SC3" HeaderText="Khối lượng" ItemStyle-HorizontalAlign="Center" />
                                <asp:BoundField DataField="DG3" HeaderText="Đơn giá" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                                <asp:BoundField DataField="TT3" HeaderText="Thành tiền" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />

                                <asp:BoundField DataField="SC4" HeaderText="Số ca" ItemStyle-HorizontalAlign="Center" />
                                <asp:BoundField DataField="DG4" HeaderText="Đơn giá" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                                <asp:BoundField DataField="TT4" HeaderText="Thành tiền" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                                <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N0}" />
                            </Columns>
                            <FooterStyle BackColor="White" ForeColor="#000066" Font-Bold="True" HorizontalAlign="Right" />
                            <HeaderStyle BackColor="White" Font-Bold="True" ForeColor="Black" Height="30px" />
                            <PagerStyle BackColor="White" ForeColor="#000066" HorizontalAlign="Left" />
                            <RowStyle BackColor="White" ForeColor="#000066" Height="30px" />
                            <SelectedRowStyle BackColor="Lavender" Font-Bold="false" />
                        </asp:GridView>
                    </div>
                </div>
            </div>
        </ContentTemplate>
        <Triggers>
            <asp:PostBackTrigger ControlID="btnSave" />
        </Triggers>
    </asp:UpdatePanel>